package com.dao;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.mappers.DepotMapper;
import com.models.Depot;

@Repository
public class DepotDao {
	@Autowired
	DepotMapper depotMapper;
	
	public List<Depot> findAll(){
	 return depotMapper.findAll();
	}
	
	public Depot findById(int id){
	 return depotMapper.findById(id);
		}
	
	public void add(Depot depot){
		 depotMapper.add(depot);
	}
	
	public void modify(Depot depot){
		 depotMapper.modify(depot);
	}
	
	public void delete(int id){
		 depotMapper.delete(id);
		}
}
